<li style="border-bottom:1px solid #ebebeb;overflow:hidden">
	<div class="span12">
		<a href="#">
			<?php echo $data->title;?>
		</a>
	</div>
	<div class="span12">
	<?php
			
		// echo CHtml::link('Preview',Yii::app()->createUrl('/article/view',array('pid'=>$data->id)), array('class'=>'btn btn-success btn-mini','target'=>'_blank'));
		
		if(currentUser() != false && $data->user_id == currentUser()->id){
			
				
			echo CHtml::link('Delete',"javascript:void(0)", array("submit"=>array('/article/delete', 'id'=>$data->id,'pid'=>$data->p_id), 
				'class'=>'btn btn-danger btn-mini','style'=>'float:right;margin-right: 10px;',
				'confirm' => 'Are you sure?'));
				
			echo CHtml::link('Revert',Yii::app()->createUrl('article/revert',array('id'=>$data->id,'pid'=>$data->p_id)), array('class'=>'btn btn-success btn-mini','style'=>'float:right'));
		?>
			
		<?php
		}
		?>
	
	</div>
</li>